package org.example.bo;

import lombok.Data;
import lombok.EqualsAndHashCode;
import org.example.enums.SearchResultEnum;

/**
 * @author lik
 */
@EqualsAndHashCode(callSuper = false)
@Data
public class SearchResultBO {

    /**
     * 查找结果
     */
    private SearchResultEnum result;

    /**
     * 对应位置
     */
    private Integer position;

    public static SearchResultBO create(SearchResultEnum result, int position) {
        SearchResultBO bo = new SearchResultBO();
        bo.setResult(result);
        bo.setPosition(position);
        return bo;
    }
}
